@extends('Layout/adminBase')
@section('css')
<link rel="stylesheet" type="text/css" href="{{asset('/bootstrap/css/bootstrap.min.css')}}">
<style type="text/css">
    .head-div{
        height: 70px;
    }
    .head-div .head-left{
        margin-left:20px;
    }
 
    .main-div{
        padding:50px;
    }
    .main-div .main-form{
        margin-left:230px;
    }
    .middle{
        height: 20px;
        background: #d5d5d8;
    }

</style>
@endsection
@section('body')
	<div id="msg">
		@include('Common/tip')
	</div>
	
	<div class="head-div">
		<div class='head-left'>
		    <h4>添加新上架积分商品</h4>
		</div>
		</div>
		
		<div class="main-div">
		<form class="form-horizontal main-form" role="form" action="{{url('admin/integral/store')}}" method="post" enctype="multipart/form-data">
			{{csrf_field()}}
		    <div class="form-group">
		        <label for="firstname" class="col-sm-2 control-label">商品名</label>
		        <div class="col-sm-5">
		            <input type="text" class="form-control" name="name" placeholder="请输入商品名称">
		        </div>
		    </div>
		    <div class="form-group">
		        <label for="firstname" class="col-sm-2 control-label">商品图片</label>
		        <div class="col-sm-5">
		            <input type="file" name="image">
		        </div>
		    </div>
		    <div class="form-group">
		        <label for="firstname" class="col-sm-2 control-label">商品详情</label>
		        <div class="col-sm-5">
		            <textarea class="form-control" rows="3" name="detail" placeholder="请输入商品详情..."></textarea>
		        </div>
		    </div>
		    <div class="form-group">
		        <label for="lastname" class="col-sm-2 control-label">积分价格</label>
		        <div class="col-sm-5">
		            <input type="text" class="form-control"  name='price' placeholder="请输入价格">
		        </div>
		    </div>
		    <div class="form-group">
		        <label for="lastname" class="col-sm-2 control-label">库存</label>
		        <div class="col-sm-5">
		            <input type="text" class="form-control"  name='stock' placeholder="请输入库存">
		        </div>
		    </div>
		    
		    <div class="form-group">
		        <div class="col-sm-offset-2 col-sm-5">
		            <button class="btn btn-success" >添加</button>
		            <button type="reset" class="btn btn-default">重置</button>
		        </div>
		    </div>
		</form>
	</div>
@endsection

@section('footer-js')
	
	<script>
	  //一次性定时器 让提示2秒后消失
	 setTimeout(function () {

	      var msg = document.getElementById('msg');

	      msg.style.display = 'none';

	    }, 2000);
	</script>

@endsection